﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/Site_Admin.master" AutoEventWireup="true" CodeFile="Timgiaovien.aspx.cs" Inherits="Admin_Timgiaovien" %>

<%@ Register src="../Controls/admin/ucLeftmenu_nd.ascx" tagname="ucLeftmenu_nd" tagprefix="uc1" %>
<%@ Register src="../Controls/admin/ucMenu_nd.ascx" tagname="ucMenu_nd" tagprefix="uc2" %>

<asp:Content ID="Content1" ContentPlaceHolderID="Menu" Runat="Server">

    <uc2:ucMenu_nd ID="ucMenu_nd1" runat="server" />

    </asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="CP_left_menu" Runat="Server">
    <uc1:ucLeftmenu_nd ID="ucLeftmenu_nd1" runat="server" />
    </asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ad_main" Runat="Server">
    
    <div class="nav_tabs">
        <ul>
            <li>
                <asp:HyperLink ID="linkqlgv" NavigateUrl="~/Admin/Giaovien.aspx" runat="server">Quản Lý Giáo Viên</asp:HyperLink>
            </li>
            <li>
                <asp:HyperLink ID="linkthemgv" NavigateUrl="~/Admin/Themgiaovien.aspx?update=0" runat="server">Thêm Giáo Viên</asp:HyperLink>
            </li>
            <li class="active_tabs">
                <asp:HyperLink ID="linktimgv" NavigateUrl="~/Admin/Timgiaovien.aspx" runat="server">Tìm Giáo Viên</asp:HyperLink>
            </li>
        </ul>
        <div class="tab_description">Bạn có thể tìm kiếm các giáo viên trong hệ thống. Nhập vào một trong các điều kiện: Mã giáo viên, tên giáo viên, địa chỉ.<br />
        Nhập nhiều điều kiện để tìm kiếm chính xác hơn.</div>
    </div>
    <asp:Panel ID="pnError" runat="server">
        <div class="error">
            <asp:Label ID="lblError" runat="server" />
        </div>
    </asp:Panel>
    <asp:Panel ID="pnSuccess" runat="server">
        <div class="thanhcong">
            <asp:Label ID="lblSuccess" runat="server" />
        </div> 
    </asp:Panel>
    
     <div class="border_wrapper">
        <div class="title">Điều kiện tìm kiếm</div>
 
        <table class="general" cellspacing="0" width="100%">        
            <tbody>
                <tr>
                    <td width="50%">
                        <label>Mã Giáo Viên</label>
                        <div class="inputs">
                            <asp:TextBox ID="txttimmgv" CssClass="select" runat="server"></asp:TextBox>
                        </div>
                    </td>
                    <td width="50%">
                        <label>Tên Giáo Viên</label>
                        <div class="inputs">
                            <asp:TextBox ID="txttimtgv" CssClass="select" runat="server"></asp:TextBox>
                        </div>
                    </td>
                    <%--<td width="50%">
                        <label>Địa Chỉ</label>
                        <div class="inputs">
                            <asp:TextBox ID="txttimdc" CssClass="select" runat="server"></asp:TextBox>
                        </div>
                    </td>--%>
                </tr>
                <tr>
                <td width="50%">
                        <label>Địa Chỉ</label>
                        <div class="inputs">
                            <asp:TextBox ID="txttimdc" CssClass="select" runat="server"></asp:TextBox>
                        </div>
                    </td> 
                </tr>
            </tbody>
        </table>
         <asp:Literal ID="ltrdiv" runat="server"></asp:Literal>
        <asp:GridView ID="gvgiaovien" runat="server" AllowPaging="True" 
            AutoGenerateColumns="False" CssClass="general" PageSize="5" Width="100%">
            <Columns>
                <asp:TemplateField>
                    <HeaderTemplate>
                        <asp:Button ID="btnxoagv" runat="server" Text="Xóa" onclick="btnxoagv_Click" />
                    </HeaderTemplate>
                    <ItemTemplate>
                        <asp:CheckBox ID="chkChon" runat="server" />
                    </ItemTemplate>
                    
                    <ItemStyle HorizontalAlign="Center" />
                </asp:TemplateField>
                <asp:BoundField DataField="id" HeaderText="ID">
                <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:TemplateField HeaderText="Tài Khoản">
                    <ItemTemplate>
                        <asp:HyperLink ID="giaovien" runat="server" 
                            NavigateUrl='<%# "Xemgiaovien.aspx?cid="+Eval("id")+"&id="+Eval("id") %>' 
                            Text='<%# Eval("teacherid") %>'></asp:HyperLink>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:BoundField DataField="fullname" HeaderText="Tên Giáo Viên">
                <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="gentle" HeaderText="Giới Tính">
                <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <%--<asp:BoundField DataField="birthday"  HeaderText="Ngày Sinh">
                <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>--%>
                <asp:BoundField DataField="adress" HeaderText="Địa Chỉ">
                <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                 <%--<asp:BoundField DataField="phone" HeaderText="SĐT">
                <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>--%>

                <asp:TemplateField HeaderText="Trạng Thái">
                    <ItemTemplate>
                        <asp:Label ID="Label1" runat="server" Text='<%# CheckTrangThai(Eval("status")) %>'></asp:Label>
                    </ItemTemplate>
                    <ItemStyle HorizontalAlign="Center" />
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Cập Nhật">
                    <ItemTemplate>
                        <asp:HyperLink ID="HyperLink2" runat="server" ImageUrl="~/images/admin/edit.png" NavigateUrl='<%# "Suagiaovien.aspx?cid="+Eval("id")+"&id="+Eval("id") %>'></asp:HyperLink>
                    </ItemTemplate>
                    <ItemStyle HorizontalAlign="Center" />
                </asp:TemplateField>
            </Columns>
        </asp:GridView>
    </div>
    <div class="button_wrapper">
        <asp:Button ID="btncapnhatdk" CssClass="submit_button" runat="server" 
            Text="Tìm kiếm" onclick="btncapnhatdk_Click" />
    </div>
</asp:Content>